<?php

/*
 * Niken Larasati
 * larasati.n@students.amikom.ac.id
 */

class hub_kel extends CI_Controller{
    public function __construct() {
        parent::__construct();
    }
    
    function form_hubkel(){
        $this->template->load('halaman_v','form_hub_keluarga_v');
    }
    
    function tambah(){
        if($this->input->post('tambah') != NULL);
        {
            $data['id_hubkel'] = $this->input->post('id_hubkel');
            $data['hub_kel'] = $this->input->post('hubkel');
            
            $this->load->model('umum_m');
            $this->umum_m->tambah('hub_kel',$data);
            $this->template->load('halaman_v','form_hub_keluarga_v');
            
        }
    }
    function  ambil_data(){
        $this->load->model('hubkel_m');
        $data['data'] = $this->hubkel_m->ambil_data();
        $this->template->load('halaman_v','form_hub_keluarga_v',$data);
                
    }
}


?>

